﻿using System.Collections.Generic;

namespace com.binance.client.model.enums
{

	/// <summary>
	///  The aggregation depth type.
	/// </summary>
	public sealed class DepthStep
	{

	  /// <summary>
	  /// step0,step1,step2,step3,step4,step5
	  /// </summary>
	  public static readonly DepthStep STEP0 = new DepthStep("STEP0", InnerEnum.STEP0, "step0");
	  public static readonly DepthStep STEP1 = new DepthStep("STEP1", InnerEnum.STEP1, "step1");
	  public static readonly DepthStep STEP2 = new DepthStep("STEP2", InnerEnum.STEP2, "step2");
	  public static readonly DepthStep STEP3 = new DepthStep("STEP3", InnerEnum.STEP3, "step3");
	  public static readonly DepthStep STEP4 = new DepthStep("STEP4", InnerEnum.STEP4, "step4");
	  public static readonly DepthStep STEP5 = new DepthStep("STEP5", InnerEnum.STEP5, "step5");

	  private static readonly IList<DepthStep> valueList = new List<DepthStep>();

	  static DepthStep()
	  {
		  valueList.Add(STEP0);
		  valueList.Add(STEP1);
		  valueList.Add(STEP2);
		  valueList.Add(STEP3);
		  valueList.Add(STEP4);
		  valueList.Add(STEP5);
	  }

	  public enum InnerEnum
	  {
		  STEP0,
		  STEP1,
		  STEP2,
		  STEP3,
		  STEP4,
		  STEP5
	  }

	  public readonly InnerEnum innerEnumValue;
	  private readonly string nameValue;
	  private readonly int ordinalValue;
	  private static int nextOrdinal = 0;

	  private readonly string step;

	  internal DepthStep(string name, InnerEnum innerEnum, string step)
	  {
		this.step = step;

		  nameValue = name;
		  ordinalValue = nextOrdinal++;
		  innerEnumValue = innerEnum;
	  }

	  public string Step
	  {
		  get
		  {
			return step;
		  }
	  }

		public static IList<DepthStep> values()
		{
			return valueList;
		}

		public int ordinal()
		{
			return ordinalValue;
		}

		public override string ToString()
		{
			return nameValue;
		}

		public static DepthStep valueOf(string name)
		{
			foreach (DepthStep enumInstance in DepthStep.valueList)
			{
				if (enumInstance.nameValue == name)
				{
					return enumInstance;
				}
			}
			throw new System.ArgumentException(name);
		}
	}

}